<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=2">
<meta name="theme-color" content="#222">
<meta name="generator" content="Hexo 5.1.1">
  <link rel="apple-touch-icon" sizes="180x180" href="/hexo/images/apple-touch-icon-next.png">
  <link rel="icon" type="image/png" sizes="32x32" href="/hexo/images/favicon-32x32-next.png">
  <link rel="icon" type="image/png" sizes="16x16" href="/hexo/images/favicon-16x16-next.png">
  <link rel="mask-icon" href="/hexo/images/logo.svg" color="#222">

<link rel="stylesheet" href="/hexo/css/main.css">


<link rel="stylesheet" href="/hexo/lib/font-awesome/css/all.min.css">

<script id="hexo-configurations">
    var NexT = window.NexT || {};
    var CONFIG = {"hostname":"youchen12138.gitee.io","root":"/hexo/","scheme":"Gemini","version":"7.8.0","exturl":false,"sidebar":{"position":"left","display":"post","padding":18,"offset":12,"onmobile":false},"copycode":{"enable":false,"show_result":false,"style":null},"back2top":{"enable":true,"sidebar":false,"scrollpercent":false},"bookmark":{"enable":false,"color":"#222","save":"auto"},"fancybox":false,"mediumzoom":false,"lazyload":false,"pangu":false,"comments":{"style":"tabs","active":null,"storage":true,"lazyload":false,"nav":null},"algolia":{"hits":{"per_page":10},"labels":{"input_placeholder":"Search for Posts","hits_empty":"We didn't find any results for the search: ${query}","hits_stats":"${hits} results found in ${time} ms"}},"localsearch":{"enable":false,"trigger":"auto","top_n_per_article":1,"unescape":false,"preload":false},"motion":{"enable":true,"async":false,"transition":{"post_block":"fadeIn","post_header":"slideDownIn","post_body":"slideDownIn","coll_header":"slideLeftIn","sidebar":"slideUpIn"}}};
  </script>

  <meta name="description" content="宽度属性宽度：  width：长度值 | 百分比 | auto  最大宽度：  max-width：长度值 | 百分比 | auto  最小宽度：  min-width：长度值 | 百分比 | auto  说明：设置块级元素和替换元素的内容宽度 高度属性高度：  height：长度值 | 百分比 | auto  最大高度：  max-height：长度值 | 百分比 | auto  最小高度：">
<meta property="og:type" content="article">
<meta property="og:title" content="CSS基础知识点--盒子模型">
<meta property="og:url" content="https://youchen12138.gitee.io/hexo/2020/08/26/CSS%E5%9F%BA%E7%A1%80%E7%9F%A5%E8%AF%86%E7%82%B9-%E7%9B%92%E5%AD%90%E6%A8%A1%E5%9E%8B/index.html">
<meta property="og:site_name" content="幽辰的博客">
<meta property="og:description" content="宽度属性宽度：  width：长度值 | 百分比 | auto  最大宽度：  max-width：长度值 | 百分比 | auto  最小宽度：  min-width：长度值 | 百分比 | auto  说明：设置块级元素和替换元素的内容宽度 高度属性高度：  height：长度值 | 百分比 | auto  最大高度：  max-height：长度值 | 百分比 | auto  最小高度：">
<meta property="og:locale" content="en_US">
<meta property="article:published_time" content="2020-08-26T06:25:04.000Z">
<meta property="article:modified_time" content="2020-08-26T06:26:31.829Z">
<meta property="article:author" content="幽辰">
<meta property="article:tag" content="CSS">
<meta name="twitter:card" content="summary">

<link rel="canonical" href="https://youchen12138.gitee.io/hexo/2020/08/26/CSS%E5%9F%BA%E7%A1%80%E7%9F%A5%E8%AF%86%E7%82%B9-%E7%9B%92%E5%AD%90%E6%A8%A1%E5%9E%8B/">


<script id="page-configurations">
  // https://hexo.io/docs/variables.html
  CONFIG.page = {
    sidebar: "",
    isHome : false,
    isPost : true,
    lang   : 'en'
  };
</script>

  <title>CSS基础知识点--盒子模型 | 幽辰的博客</title>
  






  <noscript>
  <style>
  .use-motion .brand,
  .use-motion .menu-item,
  .sidebar-inner,
  .use-motion .post-block,
  .use-motion .pagination,
  .use-motion .comments,
  .use-motion .post-header,
  .use-motion .post-body,
  .use-motion .collection-header { opacity: initial; }

  .use-motion .site-title,
  .use-motion .site-subtitle {
    opacity: initial;
    top: initial;
  }

  .use-motion .logo-line-before i { left: initial; }
  .use-motion .logo-line-after i { right: initial; }
  </style>
</noscript>

</head>

<body itemscope itemtype="http://schema.org/WebPage">
  <div class="container use-motion">
    <div class="headband"></div>

    <header class="header" itemscope itemtype="http://schema.org/WPHeader">
      <div class="header-inner"><div class="site-brand-container">
  <div class="site-nav-toggle">
    <div class="toggle" aria-label="Toggle navigation bar">
      <span class="toggle-line toggle-line-first"></span>
      <span class="toggle-line toggle-line-middle"></span>
      <span class="toggle-line toggle-line-last"></span>
    </div>
  </div>

  <div class="site-meta">

    <a href="/hexo/" class="brand" rel="start">
      <span class="logo-line-before"><i></i></span>
      <h1 class="site-title">幽辰的博客</h1>
      <span class="logo-line-after"><i></i></span>
    </a>
  </div>

  <div class="site-nav-right">
    <div class="toggle popup-trigger">
    </div>
  </div>
</div>




<nav class="site-nav">
  <ul id="menu" class="main-menu menu">
        <li class="menu-item menu-item-home">

    <a href="/hexo/" rel="section"><i class="fa fa-home fa-fw"></i>Home</a>

  </li>
        <li class="menu-item menu-item-tags">

    <a href="/hexo/tags/" rel="section"><i class="fa fa-tags fa-fw"></i>Tags<span class="badge">23</span></a>

  </li>
        <li class="menu-item menu-item-categories">

    <a href="/hexo/categories/" rel="section"><i class="fa fa-th fa-fw"></i>Categories<span class="badge">14</span></a>

  </li>
        <li class="menu-item menu-item-archives">

    <a href="/hexo/archives/" rel="section"><i class="fa fa-archive fa-fw"></i>Archives<span class="badge">127</span></a>

  </li>
  </ul>
</nav>




</div>
    </header>

    
  <div class="back-to-top">
    <i class="fa fa-arrow-up"></i>
    <span>0%</span>
  </div>


    <main class="main">
      <div class="main-inner">
        <div class="content-wrap">
          

          <div class="content post posts-expand">
            

    
  
  
  <article itemscope itemtype="http://schema.org/Article" class="post-block" lang="en">
    <link itemprop="mainEntityOfPage" href="https://youchen12138.gitee.io/hexo/2020/08/26/CSS%E5%9F%BA%E7%A1%80%E7%9F%A5%E8%AF%86%E7%82%B9-%E7%9B%92%E5%AD%90%E6%A8%A1%E5%9E%8B/">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="image" content="/hexo/images/avatar.jpg">
      <meta itemprop="name" content="幽辰">
      <meta itemprop="description" content="">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="幽辰的博客">
    </span>
      <header class="post-header">
        <h1 class="post-title" itemprop="name headline">
          CSS基础知识点--盒子模型
        </h1>

        <div class="post-meta">
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-calendar"></i>
              </span>
              <span class="post-meta-item-text">Posted on</span>
              

              <time title="Created: 2020-08-26 14:25:04 / Modified: 14:26:31" itemprop="dateCreated datePublished" datetime="2020-08-26T14:25:04+08:00">2020-08-26</time>
            </span>
            <span class="post-meta-item">
              <span class="post-meta-item-icon">
                <i class="far fa-folder"></i>
              </span>
              <span class="post-meta-item-text">In</span>
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/hexo/categories/CSS/" itemprop="url" rel="index"><span itemprop="name">CSS</span></a>
                </span>
            </span>

          

        </div>
      </header>

    
    
    
    <div class="post-body" itemprop="articleBody">

      
        <h2 id="宽度属性"><a href="#宽度属性" class="headerlink" title="宽度属性"></a>宽度属性</h2><p>宽度：</p>
<blockquote>
<p>width：长度值 | 百分比 | auto</p>
</blockquote>
<p>最大宽度：</p>
<blockquote>
<p>max-width：长度值 | 百分比 | auto</p>
</blockquote>
<p>最小宽度：</p>
<blockquote>
<p>min-width：长度值 | 百分比 | auto</p>
</blockquote>
<p>说明：设置块级元素和替换元素的内容宽度</p>
<h2 id="高度属性"><a href="#高度属性" class="headerlink" title="高度属性"></a>高度属性</h2><p>高度：</p>
<blockquote>
<p>height：长度值 | 百分比 | auto</p>
</blockquote>
<p>最大高度：</p>
<blockquote>
<p>max-height：长度值 | 百分比 | auto</p>
</blockquote>
<p>最小高度：</p>
<blockquote>
<p>min-height：长度值 | 百分比 | auto</p>
</blockquote>
<p>说明：设置块级元素和替换元素的内容高度</p>
<h2 id="哪些HTML元素可设置高和宽属性"><a href="#哪些HTML元素可设置高和宽属性" class="headerlink" title="哪些HTML元素可设置高和宽属性"></a>哪些HTML元素可设置高和宽属性</h2><ul>
<li><p>块级元素</p>
</li>
<li><p>替换元素</p>
</li>
</ul>
<p>例如：<code>&lt;input&gt;</code>、<code>&lt;img&gt;</code>、<code>&lt;textarea&gt;</code></p>
<h2 id="边框"><a href="#边框" class="headerlink" title="边框"></a>边框</h2><ul>
<li><p>边框宽度：border-width</p>
</li>
<li><p>边框颜色：border-color</p>
</li>
<li><p>边框样式：border-style</p>
</li>
</ul>
<h3 id="边框宽度"><a href="#边框宽度" class="headerlink" title="边框宽度"></a>边框宽度</h3><p>设置元素边框宽度</p>
<blockquote>
<p>border-width：thin | medium | thick | 长度值</p>
</blockquote>
<h3 id="边框颜色"><a href="#边框颜色" class="headerlink" title="边框颜色"></a>边框颜色</h3><p>设置元素边框颜色</p>
<blockquote>
<p>border-color：颜色 | transparent</p>
</blockquote>
<p>如果不给边框设置颜色，则边框颜色与元素内文本颜色一致</p>
<h3 id="边框样式"><a href="#边框样式" class="headerlink" title="边框样式"></a>边框样式</h3><p>设置元素边框样式</p>
<p>border-style：值</p>
<table>
<thead>
<tr>
<th>值</th>
<th>描述</th>
</tr>
</thead>
<tbody><tr>
<td>none</td>
<td>定义无边框。默认值</td>
</tr>
<tr>
<td>hidden</td>
<td>与none相同。除非在表格元素中解决边框冲突时</td>
</tr>
<tr>
<td>dotted</td>
<td>定义点状边框。在大多数浏览器中呈现为实线</td>
</tr>
<tr>
<td>dashed</td>
<td>定义虚线。在大多数浏览器中呈现为实线</td>
</tr>
<tr>
<td>solid</td>
<td>定义实线</td>
</tr>
<tr>
<td>double</td>
<td>定义双线</td>
</tr>
<tr>
<td>groove</td>
<td>定义3D凹槽边框</td>
</tr>
<tr>
<td>ridge</td>
<td>定义3D垄状边框</td>
</tr>
<tr>
<td>inset</td>
<td>定义3Dinset边框</td>
</tr>
<tr>
<td>outset</td>
<td>定义3Doutset边框</td>
</tr>
<tr>
<td>inherit</td>
<td>规定应该从父元素继承边框样式</td>
</tr>
</tbody></table>
<h3 id="四个方向的边框"><a href="#四个方向的边框" class="headerlink" title="四个方向的边框"></a>四个方向的边框</h3><p>4个不同方向来表示（上、下、左、右）</p>
<p>表示：</p>
<ul>
<li><p>border-[left | right | top | bottom] - width</p>
</li>
<li><p>border-[left | right | top | bottom] - color</p>
</li>
<li><p>border-[left | right | top | bottom] - style</p>
</li>
</ul>
<h3 id="边框缩写"><a href="#边框缩写" class="headerlink" title="边框缩写"></a>边框缩写</h3><p>所有方向：</p>
<blockquote>
<p>border: [宽度] | [样式] | [颜色]</p>
</blockquote>
<p>不同方向：</p>
<blockquote>
<p>border-top: [宽度] | [样式] | [颜色]</p>
</blockquote>
<blockquote>
<p>border-left: [宽度] | [样式] | [颜色]</p>
</blockquote>
<blockquote>
<p>border-right: [宽度] | [样式] | [颜色]</p>
</blockquote>
<blockquote>
<p>border-bottom: [宽度] | [样式] | [颜色]</p>
</blockquote>
<h2 id="内边距（padding）属性"><a href="#内边距（padding）属性" class="headerlink" title="内边距（padding）属性"></a>内边距（padding）属性</h2><p>设置元素的内容与边框之间的距离（内边距或填充），分4个方向（上、右、左、下）</p>
<ul>
<li><p>padding-top：长度值 | 百分比</p>
</li>
<li><p>padding-right：长度值 | 百分比</p>
</li>
<li><p>padding-bottom：长度值 | 百分比</p>
</li>
<li><p>padding-left：长度值 | 百分比</p>
</li>
</ul>
<p>说明：值不能为负</p>
<h3 id="内边距属性缩写"><a href="#内边距属性缩写" class="headerlink" title="内边距属性缩写"></a>内边距属性缩写</h3><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br></pre></td><td class="code"><pre><span class="line">padding：值1；&#x2F;&#x2F;4个方向都为值1</span><br><span class="line"></span><br><span class="line">padding：值1 值2；&#x2F;&#x2F;上下&#x3D;值1，左右&#x3D;值2</span><br><span class="line"></span><br><span class="line">padding：值1 值2 值3；&#x2F;&#x2F;上&#x3D;值1，左右&#x3D;值2，下&#x3D;值3</span><br><span class="line"></span><br><span class="line">padding：值1 值2 值3 值4；&#x2F;&#x2F;上&#x3D;值1，右&#x3D;值2，下&#x3D;值3，左&#x3D;值4</span><br></pre></td></tr></table></figure>

<h2 id="外边距（margin）属性"><a href="#外边距（margin）属性" class="headerlink" title="外边距（margin）属性"></a>外边距（margin）属性</h2><p>设置元素与元素之间的举例（外边距），4个方向（上、右、下、左）</p>
<ul>
<li><p>margin-top：长度值 | 百分比 | auto</p>
</li>
<li><p>margin-right：长度值 | 百分比 | auto</p>
</li>
<li><p>margin-bottom：长度值 | 百分比 | auto</p>
</li>
<li><p>margin-left：长度值 | 百分比 | auto</p>
</li>
</ul>
<p>说明：值可为负</p>
<ul>
<li><p>margin的值为auto，实现水平方向居中显示效果</p>
</li>
<li><p>由浏览器计算外边距</p>
</li>
</ul>
<h3 id="外边距属性缩写"><a href="#外边距属性缩写" class="headerlink" title="外边距属性缩写"></a>外边距属性缩写</h3><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br><span class="line">4</span><br><span class="line">5</span><br><span class="line">6</span><br><span class="line">7</span><br></pre></td><td class="code"><pre><span class="line">margin：值1；&#x2F;&#x2F;4个方向都为值1</span><br><span class="line"></span><br><span class="line">margin：值1 值2；&#x2F;&#x2F;上下&#x3D;值1，左右&#x3D;值2</span><br><span class="line"></span><br><span class="line">margin：值1 值2 值3；&#x2F;&#x2F;上&#x3D;值1，左右&#x3D;值2，下&#x3D;值3</span><br><span class="line"></span><br><span class="line">margin：值1 值2 值3 值4；&#x2F;&#x2F;上&#x3D;值1，右&#x3D;值2，下&#x3D;值3，左&#x3D;值4</span><br></pre></td></tr></table></figure>

<h3 id="外边距要点"><a href="#外边距要点" class="headerlink" title="外边距要点"></a>外边距要点</h3><ul>
<li><p>垂直方向，两个相邻元素都设置外边距，外边距会发生合并</p>
</li>
<li><p>合并后外边距高度 = 两个发生合并外边距的高度中最大值</p>
</li>
</ul>
<h2 id="盒子模型计算"><a href="#盒子模型计算" class="headerlink" title="盒子模型计算"></a>盒子模型计算</h2><p>盒子在页面中所占的宽度 = 左边距 + 左边框 + 左填充 + 内容宽度 + 右边距 + 右边框 + 右填充</p>
<p>高度类似</p>
<p>注意：</p>
<ol>
<li><p>如果没有Doctype文档类型声明，各浏览器按照自己的方式解析。</p>
</li>
<li><p>如果有Doctype文档类型声明，按照标准盒子模型来解析。</p>
</li>
</ol>
<h2 id="display属性"><a href="#display属性" class="headerlink" title="display属性"></a>display属性</h2><p>display有四个属性值，分别是：</p>
<ol>
<li><p>inline：元素将显示为内联元素，元素前后没有换行符</p>
</li>
<li><p>block：元素将显示为块级元素，元素前后会带有换行符</p>
</li>
<li><p>inline-block：元素将显示为行内块元素，元素呈现为inline，具有block相应特性</p>
</li>
<li><p>none：此元素不会被显示</p>
</li>
</ol>
<h3 id="重点"><a href="#重点" class="headerlink" title="重点"></a>重点</h3><figure class="highlight plain"><table><tr><td class="gutter"><pre><span class="line">1</span><br><span class="line">2</span><br><span class="line">3</span><br></pre></td><td class="code"><pre><span class="line">display: flex;</span><br><span class="line">justify-content: space-between;</span><br><span class="line">&#x2F;&#x2F; 两个属性结合使用可以让元素在容器中左右均匀分布。最常用于移动端开发</span><br></pre></td></tr></table></figure>
    </div>

    
    
    

      <footer class="post-footer">
          <div class="post-tags">
              <a href="/hexo/tags/CSS/" rel="tag"># CSS</a>
          </div>

        


        
    <div class="post-nav">
      <div class="post-nav-item">
    <a href="/hexo/2020/08/26/CSS%E5%9F%BA%E7%A1%80%E7%9F%A5%E8%AF%86%E7%82%B9-%E7%BD%91%E9%A1%B5%E5%B8%83%E5%B1%80/" rel="prev" title="CSS基础知识点--网页布局">
      <i class="fa fa-chevron-left"></i> CSS基础知识点--网页布局
    </a></div>
      <div class="post-nav-item">
    <a href="/hexo/2020/08/26/CSS%E5%9F%BA%E7%A1%80%E7%9F%A5%E8%AF%86%E7%82%B9-%E8%83%8C%E6%99%AF%E5%92%8C%E5%88%97%E8%A1%A8/" rel="next" title="CSS基础知识点--背景和列表">
      CSS基础知识点--背景和列表 <i class="fa fa-chevron-right"></i>
    </a></div>
    </div>
      </footer>
    
  </article>
  
  
  



          </div>
          

<script>
  window.addEventListener('tabs:register', () => {
    let { activeClass } = CONFIG.comments;
    if (CONFIG.comments.storage) {
      activeClass = localStorage.getItem('comments_active') || activeClass;
    }
    if (activeClass) {
      let activeTab = document.querySelector(`a[href="#comment-${activeClass}"]`);
      if (activeTab) {
        activeTab.click();
      }
    }
  });
  if (CONFIG.comments.storage) {
    window.addEventListener('tabs:click', event => {
      if (!event.target.matches('.tabs-comment .tab-content .tab-pane')) return;
      let commentClass = event.target.classList[1];
      localStorage.setItem('comments_active', commentClass);
    });
  }
</script>

        </div>
          
  
  <div class="toggle sidebar-toggle">
    <span class="toggle-line toggle-line-first"></span>
    <span class="toggle-line toggle-line-middle"></span>
    <span class="toggle-line toggle-line-last"></span>
  </div>

  <aside class="sidebar">
    <div class="sidebar-inner">

      <ul class="sidebar-nav motion-element">
        <li class="sidebar-nav-toc">
          Table of Contents
        </li>
        <li class="sidebar-nav-overview">
          Overview
        </li>
      </ul>

      <!--noindex-->
      <div class="post-toc-wrap sidebar-panel">
          <div class="post-toc motion-element"><ol class="nav"><li class="nav-item nav-level-2"><a class="nav-link" href="#%E5%AE%BD%E5%BA%A6%E5%B1%9E%E6%80%A7"><span class="nav-number">1.</span> <span class="nav-text">宽度属性</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#%E9%AB%98%E5%BA%A6%E5%B1%9E%E6%80%A7"><span class="nav-number">2.</span> <span class="nav-text">高度属性</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#%E5%93%AA%E4%BA%9BHTML%E5%85%83%E7%B4%A0%E5%8F%AF%E8%AE%BE%E7%BD%AE%E9%AB%98%E5%92%8C%E5%AE%BD%E5%B1%9E%E6%80%A7"><span class="nav-number">3.</span> <span class="nav-text">哪些HTML元素可设置高和宽属性</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#%E8%BE%B9%E6%A1%86"><span class="nav-number">4.</span> <span class="nav-text">边框</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#%E8%BE%B9%E6%A1%86%E5%AE%BD%E5%BA%A6"><span class="nav-number">4.1.</span> <span class="nav-text">边框宽度</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#%E8%BE%B9%E6%A1%86%E9%A2%9C%E8%89%B2"><span class="nav-number">4.2.</span> <span class="nav-text">边框颜色</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#%E8%BE%B9%E6%A1%86%E6%A0%B7%E5%BC%8F"><span class="nav-number">4.3.</span> <span class="nav-text">边框样式</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#%E5%9B%9B%E4%B8%AA%E6%96%B9%E5%90%91%E7%9A%84%E8%BE%B9%E6%A1%86"><span class="nav-number">4.4.</span> <span class="nav-text">四个方向的边框</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#%E8%BE%B9%E6%A1%86%E7%BC%A9%E5%86%99"><span class="nav-number">4.5.</span> <span class="nav-text">边框缩写</span></a></li></ol></li><li class="nav-item nav-level-2"><a class="nav-link" href="#%E5%86%85%E8%BE%B9%E8%B7%9D%EF%BC%88padding%EF%BC%89%E5%B1%9E%E6%80%A7"><span class="nav-number">5.</span> <span class="nav-text">内边距（padding）属性</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#%E5%86%85%E8%BE%B9%E8%B7%9D%E5%B1%9E%E6%80%A7%E7%BC%A9%E5%86%99"><span class="nav-number">5.1.</span> <span class="nav-text">内边距属性缩写</span></a></li></ol></li><li class="nav-item nav-level-2"><a class="nav-link" href="#%E5%A4%96%E8%BE%B9%E8%B7%9D%EF%BC%88margin%EF%BC%89%E5%B1%9E%E6%80%A7"><span class="nav-number">6.</span> <span class="nav-text">外边距（margin）属性</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#%E5%A4%96%E8%BE%B9%E8%B7%9D%E5%B1%9E%E6%80%A7%E7%BC%A9%E5%86%99"><span class="nav-number">6.1.</span> <span class="nav-text">外边距属性缩写</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#%E5%A4%96%E8%BE%B9%E8%B7%9D%E8%A6%81%E7%82%B9"><span class="nav-number">6.2.</span> <span class="nav-text">外边距要点</span></a></li></ol></li><li class="nav-item nav-level-2"><a class="nav-link" href="#%E7%9B%92%E5%AD%90%E6%A8%A1%E5%9E%8B%E8%AE%A1%E7%AE%97"><span class="nav-number">7.</span> <span class="nav-text">盒子模型计算</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#display%E5%B1%9E%E6%80%A7"><span class="nav-number">8.</span> <span class="nav-text">display属性</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#%E9%87%8D%E7%82%B9"><span class="nav-number">8.1.</span> <span class="nav-text">重点</span></a></li></ol></li></ol></div>
      </div>
      <!--/noindex-->

      <div class="site-overview-wrap sidebar-panel">
        <div class="site-author motion-element" itemprop="author" itemscope itemtype="http://schema.org/Person">
    <img class="site-author-image" itemprop="image" alt="幽辰"
      src="/hexo/images/avatar.jpg">
  <p class="site-author-name" itemprop="name">幽辰</p>
  <div class="site-description" itemprop="description"></div>
</div>
<div class="site-state-wrap motion-element">
  <nav class="site-state">
      <div class="site-state-item site-state-posts">
          <a href="/hexo/archives/">
        
          <span class="site-state-item-count">127</span>
          <span class="site-state-item-name">posts</span>
        </a>
      </div>
      <div class="site-state-item site-state-categories">
            <a href="/hexo/categories/">
          
        <span class="site-state-item-count">14</span>
        <span class="site-state-item-name">categories</span></a>
      </div>
      <div class="site-state-item site-state-tags">
            <a href="/hexo/tags/">
          
        <span class="site-state-item-count">23</span>
        <span class="site-state-item-name">tags</span></a>
      </div>
  </nav>
</div>



      </div>

    </div>
  </aside>
  <div id="sidebar-dimmer"></div>


      </div>
    </main>

    <footer class="footer">
      <div class="footer-inner">
        

        

<div class="copyright">
  
  &copy; 
  <span itemprop="copyrightYear">2021</span>
  <span class="with-love">
    <i class="fa fa-heart"></i>
  </span>
  <span class="author" itemprop="copyrightHolder">幽辰</span>
</div>
  <div class="powered-by">Powered by <a href="https://hexo.io/" class="theme-link" rel="noopener" target="_blank">Hexo</a> & <a href="https://theme-next.org/" class="theme-link" rel="noopener" target="_blank">NexT.Gemini</a>
  </div>

        








      </div>
    </footer>
  </div>

  
  <script src="/hexo/lib/anime.min.js"></script>
  <script src="/hexo/lib/velocity/velocity.min.js"></script>
  <script src="/hexo/lib/velocity/velocity.ui.min.js"></script>

<script src="/hexo/js/utils.js"></script>

<script src="/hexo/js/motion.js"></script>


<script src="/hexo/js/schemes/pisces.js"></script>


<script src="/hexo/js/next-boot.js"></script>




  















  

  

</body>
</html>
